package com.xiaoxi.open.design.creation.abstractfactorypattern.service.wear.summer;

import com.xiaoxi.open.design.creation.abstractfactorypattern.service.wear.factory.ClothesService;
import com.xiaoxi.open.design.creation.abstractfactorypattern.service.wear.factory.TrousersService;
import com.xiaoxi.open.design.creation.abstractfactorypattern.service.wear.factory.WearFactory;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * @ClassName SummerWearFactory
 * @Description
 * @Author xiaoxi
 * @Date 2024/5/13 22:49
 * @Version 1.0
 */
@Service
@Slf4j
public class SummerWearFactory implements WearFactory {

    @Resource(name = "summerClothesServiceImpl")
    private ClothesService clothesService;

    @Resource(name = "summerTrousersServiceImpl")
    private TrousersService trousersService;

    @Override
    public ClothesService createClothe() {
        return clothesService;
    }

    @Override
    public TrousersService createTrouser() {
        return trousersService;
    }

}
